Conventionally, an electronic compass for measuring direction by detecting geomagnetism by a magnetic sensor element has been installed in mobile terminals such as mobile phones and vehicle-mounted navigation systems. As a triaxial magnetic sensor used for detecting magnetic field components in three mutually orthogonal axial (x-axis, y-axis and z-axis) directions used in this kind of electronic compass, a sensor has been known in which three magnetic sensor elements which are an x-axis magnetic sensor element, a y-axis magnetic sensor element and a z-axis magnetic sensor element, are installed on a single substrate surface.
In such a triaxial magnetic sensor, it is necessary to have the direction of sensitivity to magnetic fields in each of the magnetic sensor elements be orthogonal to detect magnetic field components in three mutually orthogonal axial directions by the three magnetic sensor elements, respectively. When using, as the magnetic sensor elements, a magneto-resistive effect element (for example, a TMR element) that is a laminated body having a free layer and a magnetization fixed layer, in which the direction of magnetization of the free layer changes with high sensitivity in accordance with an external magnetic field and in which the resistance changes accompanying such, each magnetic sensor element is positioned such that the magnetization direction of the magnetization fixed layer of each magnetic sensor element faces in each of the directions.
For example, as shown in FIG. 16, an x-axis TMR element 301 and a y-axis TMR element 302 are laminated and formed on a first surface 201 of a substrate 200 having a first surface 201 and a second surface 202 opposite to the first surface 201, and a z-axis TMR element 303 is laminated and formed in a direction orthogonal to the first surface 201. In FIG. 16, arrows displayed overlaying each of the TMR elements 301˜303 indicate the magnetization direction of the magnetization fixed layer of each of the TMR elements 301˜303. In a triaxial magnetic sensor having this kind of configuration, the magnetization directions of the magnetization fixed layers of each of the TMR elements 301˜303 can be respectively caused to face the three axial directions (see Non-Patent Literature 1).